package com.dongnam.quanly.common.model.enumtype;

public enum LoaiHoaDon {

	HOA_DON_XUAT("Hóa Đơn Xuất"), HOA_DON_NHAN("Hóa Đơn Nhận");

	public final String id;

	private LoaiHoaDon(String id) {
		this.id = id;
	}

	public static LoaiHoaDon getLabel(String id) {
		for (LoaiHoaDon obj : LoaiHoaDon.values()) {
			if (obj.id.equals(id)) {
				return obj;
			}
		}
		return null;
	}

	public String getValue() {
		return id;
	}

	@Override
	public String toString() {
		return id; // to be used by hibernate, just #name() to get the enum name
	}
}
